var lastTab = "";

function displayTab(tabName)
{
	if (tabName != lastTab)
	{
		var tabCell = document.getElementById(tabName + "Tab");
		var tabContent = document.getElementById(tabName + "TabContent");
		document.getElementById("codeContent").innerHTML = tabContent.innerHTML;
		if (lastTab != "")
		{
			var lastTabCell = document.getElementById(lastTab + "Tab");
			lastTabCell.childNodes[0].src = lastTabCell.childNodes[0].src.replace(/\.gif$/ig, "Disabled.gif");
		}
		tabCell.childNodes[0].src = tabCell.childNodes[0].src.replace(/Disabled\.gif$/ig, ".gif");
		lastTab = tabName;
	}
}